﻿create table dbo.CodeCategories (
   CategoryId           nvarchar(10)         collate Chinese_PRC_CI_AS not null,
   CategoryOrder        int                  null,
   CategoryName         nchar(10)            collate Chinese_PRC_CI_AS null,
   CategoryDescription  nvarchar(150)        collate Chinese_PRC_CI_AS null,
   CreateBy             nvarchar(10)         collate Chinese_PRC_CI_AS null,
   CreateOn             datetime             null constraint DF_CodeCategories_CreateOn default getdate(),
   ModifyBy             nvarchar(10)         collate Chinese_PRC_CI_AS null,
   ModifyOn             datetime             null,
   constraint PK_CodeCategories primary key (CategoryId)
         on "PRIMARY"
)
on "PRIMARY"
go

execute sp_addextendedproperty 'MS_Description', 
   '编码类型ID',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CategoryId'
go

execute sp_addextendedproperty 'MS_Description', 
   '分类排序',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CategoryOrder'
go

execute sp_addextendedproperty 'MS_Description', 
   '分类名称',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CategoryName'
go

execute sp_addextendedproperty 'MS_Description', 
   '分类描述',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CategoryDescription'
go

execute sp_addextendedproperty 'MS_Description', 
   '创建人',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CreateBy'
go

execute sp_addextendedproperty 'MS_Description', 
   '创建时间',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'CreateOn'
go

execute sp_addextendedproperty 'MS_Description', 
   '更改人',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'ModifyBy'
go

execute sp_addextendedproperty 'MS_Description', 
   '更改时间',
   'user', 'dbo', 'table', 'CodeCategories', 'column', 'ModifyOn'
go
